/****** Object:  Stored Procedure dbo.spr_InsertDBClients  ******/

 use [TourIS]
 GO

 if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[spr_InsertDBClients]') and OBJECTPROPERTY(id, N'IsProcedure') = 1)
 drop procedure [dbo].[spr_InsertDBClients]
 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS OFF
 GO

 CREATE  PROCEDURE [dbo].[spr_InsertDBClients]
 (
	@address1 varchar(100),
	@address2 varchar(100),
	@clientid int,
	@clientname varchar(50),
	@compid int,
	@contactno varchar(20),
	@emailid varchar(50),
	@expirydate smalldatetime,
	@homecountry varchar(50),
	@isactive bit,
	@nic varchar(15),
	@passportno varchar(20),
	@password varchar(50),
	@reason varchar(200),
	@remarks varchar(200)
 )
 AS

 BEGIN
	SET NOCOUNT ON
	DECLARE @Err int

	INSERT INTO [Clients]
	(
		[Address1],
		[Address2],
		[ClientId],
		[ClientName],
		[CompId],
		[ContactNo],
		[EmailId],
		[ExpiryDate],
		[HomeCountry],
		[IsActive],
		[NIC],
		[PassportNo],
		[Password],
		[Reason],
		[Remarks]
	)
	VALUES
	(
		@address1,
		@address2,
		@clientid,
		@clientname,
		@compid,
		@contactno,
		@emailid,
		@expirydate,
		@homecountry,
		@isactive,
		@nic,
		@passportno,
		@password,
		@reason,
		@remarks
	)

	SET @Err = @@Error
	RETURN @Err
 END

 GO

 SET QUOTED_IDENTIFIER OFF
 GO
 SET ANSI_NULLS ON
 GO

